package com.recSystem.Entity.Converters;


import com.recSystem.Entity.DO.AuthorDO;
import com.recSystem.Entity.DTO.AuthorDTO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

/**
 * @author Legolas_PRC
 * @date 2023/4/6 21:00
 **/
@Mapper
public interface AuthorConverter {
    AuthorConverter INSTANCE = Mappers.getMapper(AuthorConverter.class);
    @Mapping(source = "authorId",target = "author_id")
    @Mapping(source = "authorName",target = "author_name")
    AuthorDTO authorDoToDto(AuthorDO authorDo);
}
